export default {
  cardType(state) {
    return state.chosenContactId !== null ? 'edit' : 'add';
  },
  currentContact(state) {
    const id = state.chosenContactId;
    return id !== null ? state.list.filter(item => item.id === id)[0] : {};
  }
}
